﻿using System;

namespace Best.SmartCms.Core.Utility
{
   public static class NLogManager
    {
        private static readonly NLog.ILogger Logger = NLog.LogManager.GetCurrentClassLogger();


        public static void LogError(string log, params object[] args)
        {
            Logger.Error(log, args);
        }

        public static void LogError(Exception ex)
        {
            Logger.Error(ex);
        }


        public static void LogError(string log, Exception ex)
        {
            Logger.Error(ex,log);
        }

      
        /// <summary>
        /// Log as Debug Level
        /// </summary>
        /// <param name="log"></param>
        /// <param name="args"></param>
        public static void LogDebug(string log, params object[] args)
        {
            Logger.Debug(log, args);
        }

       

        public static void LogTrace(string log, params object[] args)
        {
            Logger.Trace(log, args);
        }
        


        public static void LogWarn(string log, params object[] args)
        {
            Logger.Warn(log, args);
        }

        /// <summary>
        /// Log as Fatal Level
        /// </summary>
        public static void LogWarn(string log, Exception ex)
        {
            Logger.Warn(ex,log);
        }

        /// <summary>
        /// Log as Warn Level
        /// </summary>
        public static void LogWarn(Exception ex)
        {
            Logger.Warn(ex);
        }

       

        public static void LogInfo(string log, params object[] args)
        {
            Logger.Info(log, args);
        }

        

    }


   
}
